/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package subfuncsample;

/**
 *
 * @author parallels
 */
public class SubFuncSample {

    public static void main(String[] args) {
        ClientBean client1 = new ClientBean(1,"cliente 1", "dir 1");
        ClientBean client2 = new ClientBean(2,"cliente 2", "dir 2");
        
        displayClientSub(client1);
        displayClientSub(client2);
        
        System.out.println(displayClientFunc(client1));
        System.out.println(displayClientFunc(client2));
    }
    
    // Subroutine
    private static void displayClientSub (ClientBean client) {
        System.out.println ("Sub : " + client.getClientName() + "-" + client.getAddress());
    }
    
    // Function
    private static String displayClientFunc (ClientBean client) {
        return ("Func : " + client.getClientName() + "-" + client.getAddress());
    }
    
}
